<!DOCTYPE html>
<html lang="zh-CN">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>坦克大战</title>
    <script src="https://cdn.bootcdn.net/ajax/libs/echarts/5.6.0/echarts.min.js"></script>
    <link href="https://fonts.googleapis.com/css2?family=Orbitron:wght@400;700&display=swap" rel="stylesheet">
    <link rel="stylesheet" href="style.css">
</head>
<body>
    <div id="login-container">
        <div class="login-box">
            <h2>坦克大战</h2>
            <div id="login-form">
                <input type="text" id="login-username" placeholder="用户名">
                <input type="password" id="login-password" placeholder="密码">
                <button id="login-btn">登录</button>
                <div class="error-message" id="login-error"></div>
                <div class="switch-form" id="show-register">没有账号？点击注册</div>
            </div>
            <div id="register-form" style="display: none;">
                <input type="text" id="register-username" placeholder="用户名">
                <input type="password" id="register-password" placeholder="密码">
                <input type="password" id="register-confirm" placeholder="确认密码">
                <button id="register-btn">注册</button>
                <div class="error-message" id="register-error"></div>
                <div class="switch-form" id="show-login">已有账号？点击登录</div>
            </div>
        </div>
    </div>

    <div id="game-container" style="display: none;">
        <canvas id="game-canvas" width="800" height="600"></canvas>
        <div id="start-screen">
            <h1>坦克大战</h1>
            <button id="start-btn">开始游戏</button>
            <button id="load-btn">加载游戏</button>
            <div id="stats-chart" style="width: 600px; height: 400px;"></div>
        </div>
    </div>

    <script src="game.js"></script>
</body>
</html>